<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:p="http://primefaces.org/ui"
	xmlns:ui="http://java.sun.com/jsf/facelets">

<h:body>

	<ui:composition template="masterpage.xhtml">
		<ui:define name="cont">

			<h:form class="form-horizontal" action="#"
				style="border-radius: 0px;" acceptcharset="ISO-8859-1">

				<div class="form-group">
					<h:outputLabel id="outContaOrigem" value="Conta Origem"
								styleClass="col-sm-3 control-label" />
					<div class="col-sm-6">
						<h:selectOneMenu styleClass="form-control" value="#{transferenciaContaBean.contaOrigem}" converter="entityConverter">
							<f:selectItems itemValue="#{conta}" value="#{transferenciaContaBean.contaList}" var="conta" itemLabel="#{conta.titulo}"/>
						</h:selectOneMenu>
					</div>
				</div>

				<div class="form-group">
					<h:outputLabel id="outContaDestino" value="Conta Destino"
								styleClass="col-sm-3 control-label" />
					<div class="col-sm-6">
						<h:selectOneMenu styleClass="form-control" value="#{transferenciaContaBean.contaDestino}" converter="entityConverter">
							<f:selectItems itemValue="#{conta}" value="#{transferenciaContaBean.contaList}" var="conta" itemLabel="#{conta.titulo}"/>
						</h:selectOneMenu>
					</div>
				</div>

				<div class="form-group">
					<h:outputLabel id="outSaldo" value="Valor R$"
						styleClass="col-sm-3 control-label" />
					<div class="col-sm-6">
						<h:inputText id="inptValor" styleClass="form-control money"
							value="#{transferenciaContaBean.valor}">
							<f:convertNumber pattern="#,###,##0.00" />
						</h:inputText>
					</div>
				</div>

				<div class="form-group" style="margin-left: 140px;">
					<div class="col-sm-offset-2 col-sm-10">
						<h:commandButton id="btnTransferir"
							action="#{transferenciaContaBean.transferir}" value="Transferir"
							type="submit" styleClass="btn btn-primary" />
					</div>
				</div>

			</h:form>


		</ui:define>
		<ui:param name="titulo" value="Conta" />
		<ui:param name="tituloPagina" value="Transferência" />
	</ui:composition>


</h:body>
</html>